home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 1998 November / IRIX 6.5.2 Base Documentation November 1998.img / usr / share / catman / u_man / cat1 / uopt.z / uopt
Text File  |  1998-10-30  |  10KB  |  199 lines

  1.  
  2.  
  3.  
  4. UUUUOOOOPPPPTTTT((((1111))))                                                                UUUUOOOOPPPPTTTT((((1111))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      uopt - MIPS Ucode Global Optimizer
  10.  
  11. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  12.      uuuuoooopppptttt _u_n_o_p_t__f_i_l_e _o_p_t__f_i_l_e [ _s_t_r_i_n_g__f_i_l_e ] [ ----tttt _s_y_m__f_i_l_e ----iiii _i_g_n_o_r_e__f_i_l_e ----llll
  13.      _l_i_s_t__f_i_l_e ----OOOOlllliiiimmmmiiiitttt _c_o_u_n_t ----llllooooooooppppuuuunnnnrrrroooollllllll _c_o_u_n_t ] [ ----vvvv ----wwww ----bbbbbbbb ----OOOO3333 ----EEEELLLL ----EEEEBBBB
  14.      ----ddddooooaaaassssssssoooocccc ----ffff77777777aaaalllliiiiaaaassss ----ppppiiiicccc2222 ----nnnnooookkkkppppiiiiccccoooopppptttt ----kkkkppppiiiiccccoooopppptttt ----nnnnoooo____rrrr22223333 ----nnnnoooommmmuuuullllttttiiiibbbbbbbbuuuunnnnrrrroooollllllll
  15.      ----zzzzddddbbbbuuuugggg::::nnnn ]
  16.  
  17. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      uuuuoooopppptttt,,,, the MIPS _u_c_o_d_e optimizer, reads the input binary ucode file,
  19.      performs optimization on an intra-procedural, global basis and outputs
  20.      the optimized binary ucode file.  It checks the version stamp of the
  21.      ucode file, and if it does not correspond to its own stamp, a warning
  22.      message will be printed.  By convention, unoptimized binary ucode files
  23.      have the extension .B and optimized binary ucode files have the extension
  24.      .O, but uuuuoooopppptttt does not force this convention on the user.  The string file
  25.      is used for storing string and floating-point constants in each procedure
  26.      during optimization, to save memory space.  If this file name is omitted,
  27.      the file name "uoptstring" is used.  uuuuoooopppptttt first conducts a quick pre-pass
  28.      over the entire program. In the main optimization pass, it reads,
  29.      optimizes and writes out the procedures one by one in same the order that
  30.      they appear in the input file.
  31.  
  32.      The complexity of global optimization is some exponential function of the
  33.      size of the procedure (in number of basic blocks).  Thus, large
  34.      procedures take enormous amount of time to optimize.  Also, if the host
  35.      machine has only a small amount of memory, excessive swapping of memory
  36.      pages between disk physical memory further lengthens the optimization
  37.      time for large procedures.  uuuuoooopppptttt will skip optimizing a procedure if the
  38.      number of basic blocks it contains exceeds 500.  A warning message if
  39.      given so that the user is aware that the procedure is not optimized. The
  40.      default value of 500 can be overridden using the ----OOOOlllliiiimmmmiiiitttt option.
  41.  
  42.      The following options are interpreted by uuuuoooopppptttt.
  43.  
  44.      ----vvvv      Turns on verbose mode.  In this mode, uopt will print the name of
  45.              the procedure it's currently optimizing, plus a number enclosed
  46.              in parentheses that tells the number of basic blocks in that
  47.              procedure.  Optimization time is usually some exponential
  48.              function of the number of basic blocks in the procedure.  Under
  49.              -O3 optimization, an "i" after the number indicates that inter-
  50.              procedural register allocation is performed for that procedure.
  51.  
  52.      ----wwww      Suppresses warning messages.
  53.  
  54.      ----bbbbbbbb     Write out the basic block number as ucode comments in the output
  55.              ucode.  This is useful in debugging uopt.
  56.  
  57.      ----OOOO3333     Uses the inter-procedural technique when performing register
  58.              allocation.
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. UUUUOOOOPPPPTTTT((((1111))))                                                                UUUUOOOOPPPPTTTT((((1111))))
  71.  
  72.  
  73.  
  74.      ----EEEELLLL     Tells uuuuoooopppptttt.  that the target machine is little-endian.
  75.  
  76.      ----EEEEBBBB     Tells uuuuoooopppptttt.  that the target machine is big-endian.
  77.  
  78.      ----ddddooooaaaassssssssoooocccc
  79.              Performs the re-association optimization for floating-point
  80.              expressions even when the language is FORTRAN.  This violates the
  81.              FORTRAN Standard.
  82.  
  83.      ----ffff77777777aaaalllliiiiaaaassss
  84.              Assumes that there's can be aliasing among the parameters to a
  85.              procedure when the language is FORTRAN.  The FORTRAN Standard
  86.              allows the assumption by compilers that there is never any
  87.              aliasing among parameters. This assumption allows the compiler to
  88.              get better performance for the program.  If a program violates
  89.              this rule, the program may not run correctly after default
  90.              optimization; using this flag will still allow the program to run
  91.              correctly after optimization, only at a reduced performance
  92.              level.
  93.  
  94.      ----ppppiiiicccc2222   Tells uuuuoooopppptttt that the program is being compiled for execution with
  95.              dynamic shared objects.
  96.  
  97.      ----nnnnooookkkkppppiiiiccccoooopppptttt
  98.              Asks uuuuoooopppptttt not to perform the special treatment for global
  99.              variables to optimize their program accesses under shared
  100.              compilation.
  101.  
  102.      ----kkkkppppiiiiccccoooopppptttt
  103.              Asks uuuuoooopppptttt to perform the special treatment for global variables
  104.              to optimize their program accesses regardless of the shared/non-
  105.              shared compilation mode.
  106.  
  107.      ----nnnnoooo____rrrr22223333 Tells uuuuoooopppptttt that it should not use register 23.
  108.  
  109.      ----nnnnoooommmmuuuullllttttiiiibbbbbbbbuuuunnnnrrrroooollllllll
  110.              Disables unrolling for loops containing branches.
  111.  
  112.      ----zzzzddddbbbbuuuugggg::::nnnn
  113.              Tells uuuuoooopppptttt to print different debugging traces, depending on the
  114.              value of n given.  Traces are printed on a per-procedure basis,
  115.              and output to the list file specified in the -l option.  The
  116.              traces always begin with the control flow graph of the procedure.
  117.              For value 1, the local hash table and the global hash table are
  118.              printed.  For value 2, the local hash table, the global hash
  119.              table are printed; the bit vectors for the local attributes are
  120.              then printed on a per-basic-block basis.  For value 3, the global
  121.              hash table is printed, followed by the bit vectors for the
  122.              partial redundancy data flow analysis.  For value 4, the global
  123.              hash table is printed, followed by the bit vectors to determine
  124.              the live ranges of global common subexpressions.  For value 5,
  125.              the global hash table is printed, followed by the live range
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. UUUUOOOOPPPPTTTT((((1111))))                                                                UUUUOOOOPPPPTTTT((((1111))))
  137.  
  138.  
  139.  
  140.              information for all the register-residing candidates, followed by
  141.              the bit vectors related to register allocation.  For value 6, a
  142.              trace of the global register allocation via priority-based
  143.              coloring is printed.  For value 7, the inter-procedural register
  144.              allocation information is printed.
  145.  
  146.      ----tttt _s_y_m__f_i_l_e
  147.              Tells uuuuoooopppptttt the name of the symbol table file.
  148.  
  149.      ----iiii _i_g_n_o_r_e__f_i_l_e
  150.              Tells uuuuoooopppptttt to ignore specific procedures and leave them
  151.              unoptimized.  The procedures whose optimization is to be
  152.              suppressed are listed in arbitrary order in the given file, with
  153.              each line containing one procedure name starting at the first
  154.              column.
  155.  
  156.      ----llll _l_i_s_t__f_i_l_e
  157.              Uses the given file to print diagnostic information during
  158.              optimization.
  159.  
  160.      ----OOOOlllliiiimmmmiiiitttt _c_o_u_n_t
  161.              Set this parameter to the given value.  uuuuoooopppptttt will not optimize a
  162.              procedure whose size in terms of number of basic blocks exceeds
  163.              this value.
  164.  
  165.      ----llllooooooooppppuuuunnnnrrrroooollllllll _c_o_u_n_t
  166.              Set the maximum number of times that a loop will be unrolled.
  167.              The default value is 4.  Setting it to 0 or 1 will disable loop
  168.              unrolling.
  169.  
  170. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  171.      _u_c_o_d_e(1), _b_t_o_u(1), _p_p_u(1),
  172.  
  173. DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  174.      uuuuoooopppptttt assumes the input ucode file is error-free.  However, it does output
  175.      warning messages when it runs into special situations during
  176.      optimization.
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.